import 'dart:async';

main() {
  // 算术运算符

  // 加减乘除

  double price = 99.99; 
  int count = 5;
  double allPrice = price * count;

  print("总价格 $allPrice");

  //  + - * /

  double food = 22.68;

  // allPrice = allPrice + food;

  allPrice += food;

  print(allPrice);

  // 赋值运算就是 =

  int index = 0;
  index++;
  ++index;
  print(index);

  // 比较运算符
  int a = 20;
  if(a <= 20) {
    print("我胜利了");
  }
  String value = "0";

  // dart没有全等操作 
  if(0 != value) {
   
  }
  if(0 == 0) {
    print("我比较数字正确啦");
  }

  // 逻辑运算符
  // && || 

  String?  defaultValue = "默认值";
  String  currentValue = "我有值啦";

  String school = "本科";
  num workYear = 2.5;
  double Salary = 6548.25 ;

  bool condition = school == "本科" && workYear >= 2.5 && Salary <= 7000;

  bool condition2 = school == "本科" || workYear >= 2.5 || Salary <= 7000;


  print(condition2);

  // if(currentValue.isEmpty) {
  //   print(defaultValue);
  // }else {
  //   print(currentValue);
  // }
  
  // String realValue = currentValue.isEmpty || defaultValue ;

}